/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Chain;

/**
 *
 * @author Marcel
 */
public class Main {
    
    
    public static void main(String[] args) {
        Veiculo moto = new Moto();
        Veiculo carro = new Carro();
        Veiculo caminhao = new Caminhao();
        
        moto.setSuccessor(carro);
        carro.setSuccessor(caminhao);
        
        int carga = 1000;
        
        moto.processRequest(carga);
        
    }
}
